﻿@using Personalblog.Model.ViewModels;
@using Personalblog.Migrate
@model ColorfulButtonViewModel

@{
    var rnd = Random.Shared;
    var colorList = new[] {
        "btn-outline-primary",
        "btn-outline-secondary",
        "btn-outline-success",
        "btn-outline-danger",
        "btn-outline-warning",
        "btn-outline-info",
        "btn-outline-dark",
    };
    var btnColor = colorList[rnd.Next(0, colorList.Length)];
}

@* <span class="d-inline-block" tabindex="0" data-bs-toggle="popover" data-bs-trigger="hover focus" data-bs-content="@Model.Description"> *@
@*     <button class="btn btn-sm @btnColor mb-1" type="button">@Model.Name</button> *@
@* </span> *@
<a href="@Model.Url" role="button" class="btn btn-sm @btnColor mb-1" target="@Model.Target" data-bs-toggle="tooltip" data-bs-title="@Model.Description.Limit(25)">
    @Model.Name
</a>